package org.dromara.oce.domain.base;

import jakarta.validation.constraints.NotNull;
import lombok.Data;
import lombok.experimental.Accessors;
import org.dromara.common.core.exception.ServiceException;
import org.dromara.common.core.utils.ObjectUtils;

@Data
@Accessors(chain = true)
public class OceBaseQo {

    /**
     * 账号id
     */
    @NotNull
    private Long accountId;

    /**
     * 广告主ID
     */
    @NotNull
    private Long advertiserId;


    public void checkParam(){
        if(ObjectUtils.isEmpty(accountId)){
            throw new ServiceException("管家账号id不能为空");
        }
        if (ObjectUtils.isEmpty(advertiserId)) {
            throw new ServiceException("广告主id不能为空");
        }
    }

}
